package com.myRule;

import com.netflix.loadbalancer.IRule;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class MyIRule {

    @Bean
    public IRule myIRule1(){
        return new MyRandomRule();//自定义一个负载均衡的算法，采用每次使用5次后换下一个服务（轮询5此
    }


}
